﻿<Window x:Class="Kinect.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        Title="MainWindow" ResizeMode="NoResize" SizeToContent="WidthAndHeight" WindowStartupLocation="CenterScreen"
        Loaded="Window_Loaded" Closed="Window_Closed" mc:Ignorable="d" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" d:DesignHeight="733" d:DesignWidth="860">
    <Window.Resources>
        <!-- enables scrolling on ItemsControl -->
        <ControlTemplate x:Key="ScrollingItemsControl" TargetType="ItemsControl">
            <Border BorderThickness="{TemplateBinding Border.BorderThickness}" Padding="{TemplateBinding Control.Padding}"
                    BorderBrush="{TemplateBinding Border.BorderBrush}" Background="{TemplateBinding Panel.Background}" SnapsToDevicePixels="True">
                <ScrollViewer VerticalScrollBarVisibility="Auto">
                    <ItemsPresenter SnapsToDevicePixels="{TemplateBinding UIElement.SnapsToDevicePixels}" />
                </ScrollViewer>
            </Border>
        </ControlTemplate>
    </Window.Resources>
    <WrapPanel>
        <StackPanel>
            <TextBox FontSize="18" Text="骨架图" TextAlignment="Center"/>
            <ItemsControl Name="viewerHolder" />
            <StackPanel Orientation="Horizontal">
                <Label Content="Angle" Height="28" Name="labelAngle" Width="53" />
                <Slider Height="23" Name="sliderAngle"  Width="200" Minimum="-27" Maximum="27" Value="-10" IsSnapToTickEnabled="True" TickFrequency="1" ValueChanged="sliderAngle_ValueChanged" LostMouseCapture="sliderAngle_LostMouseCapture" />
            </StackPanel>
            <StackPanel Orientation="Horizontal">
                <ComboBox Height="28" Name="selectgesture" Width="80" SelectionChanged="selectgesture_SelectionChanged" >
                    <ComboBoxItem Name="ges1">0</ComboBoxItem>
                    <ComboBoxItem Name="ges2">1</ComboBoxItem>
                    <ComboBoxItem Name="ges3">2</ComboBoxItem>
                </ComboBox>
                <Label Width="140" Name="gestureName"/>
                <Button Content="Record" Height="23" Name="button1" Width="89" Click="button1_Click" />
            </StackPanel>
            <ListBox Height="330" Name="listBox1" Width="309" />
        </StackPanel>
        <StackPanel Orientation="Vertical" >
            <ItemsControl Name="viewerHolder2" Template="{StaticResource ScrollingItemsControl}" Grid.Row="1"/>
            <Button Content="记录位置" Height="23"  Name="button2" Width="75" Click="button2_Click" />
            <Button Content="开始测试" Height="23" Name="button3" Width="75" Click="button3_Click" />
        </StackPanel>
        
    </WrapPanel>
</Window>
